<template>
<div>
  <h1>Hello</h1>
  <h2>新发布的事件count*2:{{count}}</h2>
  <button @click="chen">累乘</button>
</div>
</template>

<script>
export default {
  name: "Hello",
  data(){
    return{
      count:1
    }
  },
  methods:{
    chen(){
      this.count = this.count * 2
      this.$bus.$emit('count',this.count)
    }
  }

}
</script>

<style scoped>

</style>